import React from 'react'
import { Descriptions, Tag } from 'antd'
import CardTitle from './CardTitle'
import { color, ba } from '../../utils/json'

export default function ModelFiling(props) {
  const { data } = props
  const record = data.vehicleTypeDetailsVo ? data.vehicleTypeDetailsVo : {}

  return (
    <div>
      <CardTitle title="基础信息"></CardTitle>
      <Descriptions>
        <Descriptions.Item label="车辆型号">{record.modelCn}</Descriptions.Item>
        <Descriptions.Item label="备案状态">
          {record.filingStatus || record.filingStatus === 0 ? (
            <Tag color={color[record.filingStatus]}>
              {ba[record.filingStatus]}
            </Tag>
          ) : (
            '--'
          )}
        </Descriptions.Item>
        <Descriptions.Item label="发动机型号">
          {record.engineType}
        </Descriptions.Item>
        <Descriptions.Item label="燃料类型">
          {record.engineFuelType}
        </Descriptions.Item>
        <Descriptions.Item label="排放水平">
          {record.engineEmissionLevel}
        </Descriptions.Item>
        <Descriptions.Item label="尿素箱容积(L)">
          {record.pcdUreaTankCapacity}
        </Descriptions.Item>
        <Descriptions.Item label="整车生产企业">
          {record.vehicleFirm}
        </Descriptions.Item>
        <Descriptions.Item label="厂牌品牌">
          {record.factoryModel}
        </Descriptions.Item>
        <Descriptions.Item label="驱动桥主减速比">
          {record.reductionRatio}
        </Descriptions.Item>
        <Descriptions.Item label="前进档个数">
          {record.transmissionForwardNumber}
        </Descriptions.Item>
        <Descriptions.Item label="各档速比">
          {record.transmissionGearRatio}
        </Descriptions.Item>
      </Descriptions>
      {/* <CardTitle title="附加信息"></CardTitle>
      <Descriptions>
        <Descriptions.Item label="车型详情">
          {record.modelCnDetail}
        </Descriptions.Item>
        <Descriptions.Item label="车系编码">
          {record.seriesCode}
        </Descriptions.Item>
        <Descriptions.Item label="环保信息公开编号">
          {record.epaPublicInfoNum}
        </Descriptions.Item>
        <Descriptions.Item label="用途类型">
          {record.modelType}
        </Descriptions.Item>
        <Descriptions.Item label="产地">{record.productArea}</Descriptions.Item>
        <Descriptions.Item label="底盘型号">
          {record.chassisModel}
        </Descriptions.Item>
        <Descriptions.Item label="底盘生产企业">
          {record.chassisFirm}
        </Descriptions.Item>
        <Descriptions.Item label="最大允许装载质量">
          {record.maxAllowMass}
        </Descriptions.Item>
        <Descriptions.Item label="最大允许牵引总质量">
          {record.maxAllowDrawMass}
        </Descriptions.Item>
        <Descriptions.Item label="鞍座最大允许承载质量">
          {record.maxAllowableBearingMass}
        </Descriptions.Item>
        <Descriptions.Item label="最高车速">
          {record.maxSpeed}
        </Descriptions.Item>
        <Descriptions.Item label="最小离地间隙">
          {record.minGroundClearance}
        </Descriptions.Item>
        <Descriptions.Item label="车辆滑行系数(A、B、C)">
          {record.vehicleSlidingCoefficient}
        </Descriptions.Item>
        <Descriptions.Item label="轴数/列车轴数">
          {record.axlesNumber}
        </Descriptions.Item>
        <Descriptions.Item label="轴距 (mm)">
          {record.wheelbase1}
        </Descriptions.Item>
        <Descriptions.Item label="轮距(前/后) (mm)">
          {record.wheelbase2}
        </Descriptions.Item>
        <Descriptions.Item label="车身（或驾驶室）型式">
          {record.bodyModel}
        </Descriptions.Item>
        <Descriptions.Item label="轮胎数">
          {record.tireNumber}
        </Descriptions.Item>
        <Descriptions.Item label="轮胎生产企业">
          {record.tireManufacturer}
        </Descriptions.Item>
        <Descriptions.Item label="轮胎规格">
          {record.tireSpec}
        </Descriptions.Item>
        <Descriptions.Item label="轮胎气压 (kPa)">
          {record.tirePressure}
        </Descriptions.Item>
        <Descriptions.Item label="接近角/离去角(°)">
          {record.approachDepartureAngle}
        </Descriptions.Item>
        <Descriptions.Item label="变速箱">
          {record.transmissionName}
        </Descriptions.Item>
        <Descriptions.Item label="变速器生产企业">
          {record.transmissionFirm}
        </Descriptions.Item>
        <Descriptions.Item label="型式/操纵方式">
          {record.transmissionType}
        </Descriptions.Item>
        <Descriptions.Item label="变速器型号">
          {record.transmissionModel}
        </Descriptions.Item>
        <Descriptions.Item label="油箱容积">
          {record.pcdFuelTankCapacity}
        </Descriptions.Item>
        <Descriptions.Item label="允许吸收的最大功率（kW)">
          {record.allowedMaxPower}
        </Descriptions.Item>
        <Descriptions.Item label="ESC试验ABC转速（r/min）">
          {record.abcSpeed}
        </Descriptions.Item>
        <Descriptions.Item label="设备监控版本号">
          {record.tmsMonirotVersion}
        </Descriptions.Item>
        <Descriptions.Item label="驱动型式及位置">
          {record.driveType}
        </Descriptions.Item>
      </Descriptions> */}
      <CardTitle title="备案记录"></CardTitle>
    </div>
  )
}
